
<script setup lang="ts">
import { useDrag } from "./useDrag";

const { onmMouseDown } = useDrag();
</script>


<template>
  <div class="useDrag-wrap" @mousedown="onmMouseDown">
    Drge Btn!
  </div>
</template>



<style>
.useDrag-wrap {
  position: absolute;
  top: calc(50% + var(--drag-y, 0px));
  left: calc(50% + var(--drag-x, 0px));
  transform: translate(-50%, -50%);
  background-color: #098;
  padding: 20px;
  cursor: grab;
}
</style>
